home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Shareware Grab Bag
/
Shareware Grab Bag.iso
/
007
/
coreaids.arc
/
STK_STRT.ASM
< prev
next >
Wrap
Assembly Source File
|
1987-06-25
|
742b
|
34 lines
; DESC: start a user stack V1.00
; SAMPLE: STK_STRT
; ##################################################################
STACK Segment Para Common 'STACK'
DW 100H DUP(0)
STACK Ends
STK_STRC Segment
Assume CS:STK_STRC,SS:STACK
Public STK_STRT
;notice.
DB 'STK_STRT - V1.00, Copyright 1987, CoreTechs ',0DH,0AH
STK_STRT Proc Near
Cli ;disable interrupts.
Pop CS:WORD PTR[0] ;save return address.
Mov CS:WORD PTR[10],SS ;save system stack offsets.
Mov CS:WORD PTR[12],SP
Mov SP,STACK ;setup user stack.
Mov SS,SP
Mov SP,100H
Push CS:WORD PTR[0] ;replace return address.
Sti ;enable interrupts.
Ret
STK_STRT Endp
STK_STRC Ends
End